<?php
require_once 'init_app.php';

set_time_limit(0); 

// Одежда - для женщин, мужчин и детей
/*$url = 'http://export.admitad.com/ru/webmaster/websites/121512/products/export/?user=Sianukvil&code=bc752de506&region=RU&price_from=&price_to=&category=312&category=1702&category=1848&keyword=&format=xml';
$n = Model_ProductParser_Admitad::instance()->parse($url);
echo 'General - '.$n."\n";  */

// Wildberries
$url = 'http://export.admitad.com/ru/webmaster/websites/121512/products/export_adv_products/?user=Sianukvil&code=bc752de506&advcampaign_id=4102&format=xml';
$shop = ORM::factory('shop', 4102);
$n = Model_ProductParser_Admitad::instance()->parse($url, $shop);
echo 'Wildberries - '.$n."\n";

echo "ok\n";